//
//  ApiCilent.h
//  CarDeal_IOS
//
//  Created by 孙可 on 2018/8/20.
//  Copyright © 2018年 sunke. All rights reserved.
//

#import <Foundation/Foundation.h>
#import "AFNetworking.h"

@interface ApiCilent : AFHTTPSessionManager

+ (id)sharedClient;

- (void)patchData:(NSString *)aPath
                     withParams:(NSDictionary*)params
                       andBlock:(void (^)(id data, NSError *error))block;

- (void)postData:(NSString *)aPath
       withParams:(NSDictionary*)params
         andBlock:(void (^)(id data, NSError *error))block;

- (void)postJsonData:(NSString *)aPath
      withParams:(NSDictionary*)params
        andBlock:(void (^)(id data, NSError *error))block;

- (void)postPayJsonData:(NSString *)aPath
          withParams:(NSDictionary*)params
            andBlock:(void (^)(id data, NSError *error))block;

- (void)getData:(NSString *)aPath
          withParams:(NSDictionary*)params
            andBlock:(void (^)(id data, NSError *error))block;

@end
